package com.kurumi.medical.model;

import java.util.ArrayList;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonIgnore;

/**
 * 药物过敏信息
 * @author lyh
 *
 */
public class HospitalVisitDrugAllergyInfo {

	/**
	 * visitGuid
	 */
	private String visitGuid;
	
	/**
	 * 过敏药物明细
	 */
	private List<HospitalVisitDrugAllergyRecord> drugAllergyRecords = new ArrayList<HospitalVisitDrugAllergyRecord>();

	@JsonIgnore
	public void clearEmpty(){
		for (int i = this.drugAllergyRecords.size()-1; i >=0; i--) {
			HospitalVisitDrugAllergyRecord drugAllergyRecord = this.drugAllergyRecords.get(i);
			if(drugAllergyRecord.isEmpty()){
				this.drugAllergyRecords.remove(i);
			}
		}
	}
	
	
	public String getVisitGuid() {
		return visitGuid;
	}

	public void setVisitGuid(String visitGuid) {
		this.visitGuid = visitGuid;
	}

	public List<HospitalVisitDrugAllergyRecord> getDrugAllergyRecords() {
		return drugAllergyRecords;
	}

	public void setDrugAllergyRecords(
			List<HospitalVisitDrugAllergyRecord> drugAllergyRecords) {
		this.drugAllergyRecords = drugAllergyRecords;
	}
	
	
}
